package com.example.curd.service.impl;


import com.example.curd.entity.Good;
import com.example.curd.mapper.GoodMapper;
import com.example.curd.service.IGoodService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;


/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author dakai
 * @since 2021-04-18
 */
@Service
public class GoodServiceImpl implements IGoodService {

  @Autowired
  GoodMapper goodMapper;
  @Override
  public List<Good> selectAllGood() {
    return null;
  }

  @Override
  public Good getGoodById(Integer gid) {
    return goodMapper.getGoodById(gid);
  }

  @Override
  public void updateGood(Good good) {
    goodMapper.updateGood(good);
  }

  @Override
  public void deleteGood(Integer gid) {
    goodMapper.deleteGood(gid);
  }

  @Override
  public void addGood(Good good) {
    goodMapper.addGood(good);
  }
}
